.TH adddrain 1  "January 8, 2019" "version 1.0.001" "USER COMMANDS"
.SH NAME
adddrain \- adds river basin to coordinate file
.SH SYNOPSIS
.B adddrain
[\-longheader] [\-downstream] [\-short]
.I coord_all.clm coord.clm drainage.clm coord_basin.clm
.SH DESCRIPTION
Program creates new coordinate file with cells added that are part of the river basin. This has to be done for simulations with river routing enabled.
.SH OPTIONS
.TP
\-longheader
Long (version 2) header assumed for CLM files
.TP
\-downstream
By default only cell from upstream are added. Enabling this flags also cells from downstream will be added
.TP
\-short
The datatype of coordinate data is set to short, default is float
.TP
.I coord_all.clm
Global coordinate file
.TP
.I coord.clm
Coordinate file river basins should be added
.TP
.I drainage.clm
River routing file corresponding to coord_all.clm
.TP
.I coord_basin.clm
New coordinate file created
.SH EXAMPLES
.TP
.B adddrain -short
grid.clm coord.clm drainage.clm coord_basin.clm
.PP
.SH EXIT STATUS
Non zero is returned in case of failure.

.SH AUTHORS

For authors and contributors see AUTHORS file

.SH COPYRIGHT

(C) Potsdam Institute for Climate Impact Research (PIK), see COPYRIGHT file


.SH SEE ALSO
lpjml(1), txt2clm(1), cru2clm(1), clm(5)
